<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateSystemStoreTable extends Migration
{
    /**
     * Run the migrations.
     *门店自提
     * @return void
     */
    public function up()
    {
        Schema::create('system_store', function (Blueprint $table) {
            $table->id()->comment('门店自提');
            $table->string('name')->comment('门店名称');
            $table->string('introduction')->comment('简介');
            $table->string('phone')->comment('手机号码');
            $table->string('address')->comment('省市区');
            $table->string('detailed_address')->comment('详细地址');
            $table->string('image')->comment('门店logo');
            $table->string('oblong_image')->comment('门店推荐图');
            $table->string('latitude')->comment('纬度');
            $table->string('longitude')->comment('经度');
            $table->timestamp('valid_time')->nullable()->comment('核销有效日期');
            $table->timestamp('day_time')->nullable()->comment('每日营业开关时间');
            $table->tinyInteger('status')->default(1)->comment('是否显示:0不显示 1显示(默认)');
            $table->softDeletes();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('system_store');
    }
}
